package nineteen;

/**
 * 我的演示
 *
 * @author sun.ye
 * @since 2020-05-01 17:15
 */
public class MyDemo {
    public static void main(String[] args) {
        System.out.println(DemoEnum.AENUM.getName());
        System.out.println(DemoEnum.AENUM.getValue());
        DemoEnum.AENUM.setName("?");
        System.out.println(DemoEnum.AENUM.getName());
        System.out.println(DemoEnum.AENUM.getValue());

    }

}


enum DemoEnum{
    /**
     * 演示
     */
    AENUM("AENUM","0000"),
    BENUM("BENUM","0002");

    DemoEnum(String name, String value) {
        this.name = name;
        this.value = value;
    }

    private String name;
    private String value;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }
}